<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<span id="${uuid}"></span>
<div class="box_tc_s">
    <div class="box_tc_s">
        <div style="float: right;width: 300px;">
            <h3>已选择的结构</h3>
            <div data-id="chooseItem" class="choose-item-box">
                <div class="choose-tip">
                    暂时未选择相关数据
                </div>
            </div>
        </div>
        <div style="margin-right: 305px;padding-right: 10px;border-right: 2px solid #2daacd">
            <h3>可选的结构列表</h3>
            <div class="grid-wrap" style="margin-top: 0">
                <table data-id="grid"></table>
            </div>
        </div>
    </div>
    <div data-id="news_tb" class="nsdb">
        <a data-href="${pageContext.request.contextPath}/app/api/pbom/toSearch" data-key="search" iconCls="fa fa-search fa-lg"
           plain="true">搜索</a>
        <a data-href="#" data-key="search_all" iconCls="fa fa-refresh fa-lg" plain="true">搜索全部</a>
    </div>
    <div data-id="user_list_btn">
        <a data-href="#" data-id="{{id}}" data-key="view" iconCls="fa fa-eye fa-lg" plain="true">详情查看</a>
    </div>
</div>
<script language="javascript">
    seajs.use("apps/pbom/choose", function(page){
        page.init("${pageContext.request.contextPath}", "${uuid}");
        var uuid = "${uuid}";

        $[uuid] = {
            pageFactory: page.pageFactory,
            getChooseData:page.getChooseData
        }
    });

    function choose_pbom_child(win){
        if (!$["${uuid}"].pageFactory.getJqDom('baseForm').form('validate')) {
            return false;
        }
        win.wait("start", "保存中,请稍候.");
        var grid = $["${uuid}"].pageFactory.getJqDom("grid");
        win.callback(true, $["${uuid}"].getChooseData());
        win.wait("end");
        win.close();
    }
</script>